/*
 * @Description: 我要举报
 * @Author: iamsmiling
 * @Date: 2021-06-09 21:48:49
 * @LastEditTime: 2021-06-09 22:07:27
 */

import 'package:get/get.dart';

enum ReportReason {
  ad,

  illegal,
  other
}

extension ReportReasonKit on ReportReason {
  String get name =>
      {
        ReportReason.ad: "广告骚扰信息",
        ReportReason.illegal: "政治敏感、涉黄、涉赌等违法内容",
        ReportReason.other: "其他"
      }[this] ??
      '';
}

class ReportController extends GetxController {
  ReportReason reason = ReportReason.ad;

  void selectReason(bool? flag, ReportReason reportReason) {
    if (flag == true) {
      reason = reportReason;
    }
    update();
  }
}
